﻿using Abcd.Warehouse.Domain;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.EntityFrameworkCore.Sqlite;
using Volo.Abp.Modularity;

namespace Abcd.Warehouse.EFCore
{
    [DependsOn(
        typeof(AbpEntityFrameworkCoreSqliteModule),
        typeof(AbcdWarehouseDomainModule)
    )]
    public class AbcdWarehouseEFCoreModule:AbpModule
    {
        public override void ConfigureServices(ServiceConfigurationContext context)
        { 
            var services = context.Services;

            services.AddAbpDbContext<AbcdWarehouseDbContext>(options => {
                options.AddDefaultRepositories(includeAllEntities: true);
            });
        }
    }
}